package com.sky.task;

import lombok.extern.slf4j.Slf4j;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

import java.time.DateTimeException;
import java.util.Date;

@Slf4j
@Component
public class Scheduling {
    @Scheduled(cron = "*/5 * * * * ?")
    public void test(){
    log.info("定时执行",new Date());
    }
}
